#include<stdio.h>
#include<stdlib.h>
#include<conio.h>
int main()
{
	int i,j;
	int x=10;
	int y=5;
	char input;
	int fire=0;
	
	while(1)
		{
			system("cls");
			if(fire==0)
				{	for(i=1;i<=x;i++)
						printf("\n");
				}
			else 
				{
					for(i=1;i<=x;i++)
					{
						printf(" ");
						printf("      |\n");
					}
				fire=0;
				}
			for(j=1;j<=y;j++)
				printf(" ");
				printf("  *\n");
			for(j=1;j<=y;j++)
				printf(" ");
				printf("*****\n");
			for(j=1;j<=y;j++)
				printf(" ");
				printf(" * * ");
			if(kbhit())
			{
				input=getch();
				if(input=='w')
					x--;
				if(input=='s')
					x++;
				if(input=='a')
					y--;
				if(input=='d')
					y++;
				if(input==' ')
				    fire=1;
			}
		}
		return 0;
 } 
